package com.itheima.demo;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

@Data
@Configuration
@ConfigurationProperties(prefix =  "aliyun.oss") // 以aliyun.oss开头的属性 封装到AliyunOssConfig中
public class AliyunOssConfig {

    private String endpoint;

    private String bucket;

    private User user;

    @Data
    public static class User{
        private String username;
        private String password;
    }

}